package com.wesh.home.dao.es;

import com.wesh.home.model.Tender;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.PageRequest;
import org.springframework.data.elasticsearch.repository.ElasticsearchRepository;
import org.springframework.stereotype.Repository;

@Repository
public interface SearchRepository extends ElasticsearchRepository<Tender, String> {

    /**
     * 根据 productName 查询，根据 方法 名称查询
     * @param productName
     * @param pageRequest
     * @return
     */
    Page<Tender> findByProductName(String productName, PageRequest pageRequest);
}
